#通过登录获取token
import requests
def token():
    #通过登录的接口返回值获取token
    head={'Content-Type':'application/x-www-form-urlencoded'}
    date={'username':19999999999,'password':123456}
    login=requests.post('http://182.92.197.48:8080/login',data=date,headers=head,timeout=2)
    r=login.json()
    crm_token=r['Admin-Token']
    # print(crm_token)
    return crm_token

# token()